<?php

use yii\db\Migration;

/**
 * Class m200621_065758_memberinfos
 */
class m200621_065758_memberinfos extends Migration
{
    /**
     * {@inheritdoc}
     */
    public function safeUp()
    {
        $this->execute(
            "CREATE TABLE {{%memberinfos}} (
                `infoId` int(11) NOT NULL AUTO_INCREMENT COMMENT '会员信息编号',
                `memberKey` varchar(200) DEFAULT NULL COMMENT '会员标识',
                `realName` varchar(20) DEFAULT NULL COMMENT '真实姓名',
                `idCardNo` varchar(20) DEFAULT NULL COMMENT '身份证号',
                `ctime` int(11) DEFAULT NULL COMMENT '创建时间',
                PRIMARY KEY (`infoId`)
            ) ENGINE=MyISAM AUTO_INCREMENT=0 DEFAULT CHARSET=utf8"
        );
    }

    /**
     * {@inheritdoc}
     */
    public function safeDown()
    {
        $this->dropTable('{{%settings}}');
    }
}
